package com.zbs.framework.swagger.scan;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Import;
import org.springframework.core.annotation.AliasFor;

import java.lang.annotation.*;

@Target({ElementType.TYPE, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
@Import(ApiScannerRegistrar.class)//这个是我们的关键，实际上也是由这个类来扫描的
@Documented
@ComponentScan("com.zbs.framework.swagger")
public @interface ApiScan {

    @AliasFor("basePackage")
    String[] value() default {};

    @AliasFor("value")
    String[] basePackage() default {};

    /*
    是否检查参数
     */
    boolean enableCheckParams() default false;

    /*
    是否开启不扫描RequestMapping
     */
    boolean enableRequestMapping() default false;

}